package com.yswy.app.controller;

import com.yswy.app.dto.LogRecordVo;
import com.yswy.app.service.LogRecordService;
import com.yswy.app.service.UserLoginLogService;
import com.yswy.common.model.ResultModel;
import com.yswy.common.vo.dto.BaseFilter;
import com.yswy.theater.service.TheaterPlayLookLogService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

import javax.servlet.http.HttpServletRequest;

import static com.yswy.domain.common.util.TokenUtils.getUserId;

@RestController
@RequestMapping("/log")
@Api(description = "记录")
public class LogController {

    @Autowired
    private LogRecordService logRecordService ;
    


    @PostMapping("/addLogRecord")
    @ApiOperation(value = "事件记录")
    public ResultModel addLogRecord(  @RequestBody LogRecordVo logRecordVo ,
                                                HttpServletRequest request) {
        logRecordService.addLogRecord(logRecordVo ,getUserId(request));
        return ResultModel.ok();
    }



}
